#ifndef MATCH_H
#define MATCH_H
#include <iostream>
using namespace std;
class Match
{
private:
    static const int date=20160714;//静态常量
	int number;
	int team;
	int grade;
	int member[10];//队员号码
	static int count;//静态成员
public:
	friend class Print;//友元类
	Match()
	{
		for(int i=0;i<10;i++)member[i]=0;
		number=0;
		team=0;
		grade=0;
	}
	//构造函数
	Match(int number,int team,int grade)
	{
		for(int i=0;i<10;i++)member[i]=0;
		this->number=number;
		this->team=team;
		this->grade=grade;
		cout<<"构造重载函数调用"<<endl;
	}
	//构造重载函数
	Match(const Match &m);//常引用
	~Match();
	friend void conclu(Match &m1,Match &m2);//友元函数
	void add(int team,int number=10,int grade=100){this->number=number;this->team=team;this->grade=grade;}//默认形参
	void change(int grade,int number,int team,int member[]);
	int getnumber(){return number;}
	int getgrade(){return grade;}
	int getteam(){return team;}
	int getdate(){return date;}
	int getpeople(int i){return member[i];}
	static void showcount()
	{
		cout<<"Object count= "<<count<<endl;
	}
};
class Group
{
private:
	int date;
	int number;
	int grade;
	Match m1,m2;
public:
	Group(Match xm1,Match xm2);//组合
	Group(Group &g);
	~Group();
};
class Print
{
private:
	Match m1,m2;
public:
	void compare(Match &m1,Match &m2);
};
class Score:private Match
{
private:
	int score[10];
	int bestguy;
	int bestscore;
public:
	void perscore(int grade,int number,int team,int member[],int score[]);
};
#endif